package com.j2ee.cglib.proxy;

import org.junit.Test;

public class PersonTest {
	
	@Test
	public void testCglib() {
		Object target = new Person() ;
		Transaction transaction = new Transaction() ;
		//创建拦截器对象
		PersonInterceptor interceptor = new PersonInterceptor(target, transaction) ;
		Person person = (Person) interceptor.createProxy();
		person.savePerson();
	}

}
